// 导入封装的请求实例
import request from '@/utils/request'
// 请求筛选数据树
export const getExamTree = () => {
  return request({
    url: '/subject/tree',
    method: 'get'
  })
}
// 请求列表
export const getExamListApi = params => {
  return request({
    url: '/exam/exam',
    method: 'get',
    params
  })
}
// 删
export const delExamListApi = (id) => {
  return request({
    url: `/exam/exam/${id}`,
    method: 'DELETE'
  })
}
// 增
export const addExamListApi = (data) => {
  return request({
    url: `/exam/exam`,
    method: 'POST',
    data
  })
}
// 获取试卷信息
export const getPaperApi = (params) => {
  return request({
    url: `/exam/paper`,
    method: 'GET',
    params
  })
}
// 获取已推送班级的信息
export const getLookClass = (params) => {
  return request({
    url: `/class/class`,
    method: 'GET',
    params
  })
}
// 推送班级/解除班级 绑定
export const bindClass = (data) => {
  return request({
    url: `/exam/exam/bindClass`,
    method: 'POST',
    data
  })
}
